package com.shine.filter;

import com.shine.constant.GatewayConstant;
import jakarta.servlet.*;
import lombok.extern.slf4j.Slf4j;
import org.springframework.core.Ordered;
import org.springframework.stereotype.Component;

import java.io.IOException;

/**
 * @author huihui
 * @date 2024/11/4 11:24
 * @description RequestLogFilter 请求日志
 */
@Slf4j
@Component
public class RequestLogFilter implements Filter, Ordered {

    @Override
    public int getOrder() {
        return GatewayConstant.FILTER_ORDER_REQUEST_LOG;
    }

    @Override
    public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException, ServletException {
        chain.doFilter(request, response);
    }

}
